<template>
  <div class="manageDis">
    创建渠道
    <a-card>
      <a-form
        :form="form"
        :label-col="{ span: 5 }"
        :wrapper-col="{ span: 12 }"
        @submit="handleSubmit"
      >
        <a-form-item label="会员号">
          <a-input v-decorator="['MemberId']" />
        </a-form-item>
        <a-form-item label="订单编号">
          <a-input v-decorator="['OrderNo']" />
        </a-form-item>
        <a-form-item label="交易金额">
          <a-input v-decorator="['TradeAmt']" />
        </a-form-item>
        <a-form-item label="交易数量">
          <a-input v-decorator="['TradeQty']" />
        </a-form-item>
        <a-form-item label="交易类型">
          <a-input v-decorator="['TradeType']" />
        </a-form-item>
        <a-form-item label="Commission1">
          <a-input v-decorator="['Commission1']" />
        </a-form-item>
        <a-form-item label="用户豆币余额">
          <a-input v-decorator="['UserBeans']" />
        </a-form-item>
        <a-form-item label="支付方式">
          <a-input v-decorator="['PayMentMtd']" />
        </a-form-item>
        <a-form-item label="分销商编号">
          <a-input v-decorator="['DisbNO']" />
        </a-form-item>
        <a-form-item label="是否提现">
          <a-input v-decorator="['IsCashOut']" />
        </a-form-item>
        <a-form-item :wrapper-col="{ span: 12, offset: 5 }">
          <a-button type="primary" html-type="submit"> Submit </a-button>
        </a-form-item>
      </a-form>
    </a-card>
  </div>
</template>
<script>
import { createMem } from "../../services/dataSource";

export default {
  name: "manageDis",
  data() {
    return {
      formLayout: "horizontal",
      form: this.$form.createForm(this, { name: "coordinated" }),
    };
  },
  methods: {
    handleSubmit(e) {
      e.preventDefault();
      this.form.validateFields((err, values) => {
        console.log(err);
        if (!err) {
          createMem(...values).then((res) => {
          });
        }
      });
    },
  },
};
</script>
<style lang="less">
</style>